home *** CD-ROM | disk | FTP | other *** search
- /*
- * saveclip - Save the contents of the clipboard to a file.
- */
-
- parse arg fname
- address cliptool
- 'getnumber var before'
- 'paste'
- 'getnumber var after'
- if before < after then do
- 'getcreateicons var state'
- 'createicons off' /* we don't want an icon */
- 'saveas name' fname 'dir' pragma('Directory')
- 'erase'
- 'createicons' state /* restore the previous state */
- end
- else say 'Clipboard is empty'
-